project(MEASURE_NATIVE_LIB)

add_library(measure_native_lib SHARED measure_native_lib_impl.cpp)
target_include_directories(measure_native_lib PRIVATE "${ANI_INCLUDE_DIR}")
target_include_directories(measure_native_lib PRIVATE ${PANDA_HELPERS_SOURCE_DIR})

compile_panda_source_list(
    TARGET_NAME measure_native_lib_abc
    SOURCE_LIST
        "MeasureNativeLib.ets"
    EXTRA_DEPS
        measure_native_lib
)

ark_aot(
    TARGET_NAME
        measure_native_lib_aot
    ABC_FILE
        "MeasureNativeLib.abc"
    EXTRA_DEPS
        measure_native_lib_abc
)

add_custom_target(measure_native_lib_srcs
    DEPENDS
        measure_native_lib_aot
        measure_native_lib_abc
)
